using System;
using System.IO;
using System.Reflection;
using SoftwareMonkeys.FileNodes;

namespace SoftwareMonkeys.FileNodes.CreateExampleNodeConsole
{
	class Program
	{
		public static void Main(string[] args)
		{
			Console.WriteLine("Creating example properties file...");
			
			string nodeFile = Path.GetDirectoryName(Assembly.GetExecutingAssembly().Location)
				+ Path.DirectorySeparatorChar
				+ "ExampleNode.node";
			
			FileNode node = new FileNode(
				nodeFile,
				new FileNodeSaver()
			);
			
			node.Name = "Example";
			node.Properties.Add("TestProperty", "TestValue");
			node.Properties.Add("TestProperty2", "TestValue2");
			
			node.Save();
		}
	}
}